Skip to content

Conversation

@blt
Copy link
Collaborator

@blt blt commented Jan 6, 2026

What does this PR do?

Introduced Shannon entropy calculation into the fingerprint mechanism, answering the question of how much entropy our payloads have in them. My pitch is that we should never decrease entropy but that might be naive. At least now we'll know which direction things move in. Also added fingerprints for syslog and splunk_hek.

Add CI to our micro-benchmark suite to make sure it doesn't accumulate compilation errors as lading's internal API changes.

@blt blt requested a review from a team as a code owner January 6, 2026 01:31
@blt blt force-pushed the fix-bench-compile branch from da9c4e6 to 0ecddaa Compare January 6, 2026 01:43

/// Compute Shannon entropy (bits per byte) of a byte sequence.
#[allow(clippy::cast_precision_loss)]
fn shannon_entropy(data: &[u8]) -> f64 {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks worth a couple of tests

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Addressed in 4d3cb7d

Introduced Shannon entropy calculation into the fingerprint mechanism,
answering the question of how much entropy our payloads have in
them. My pitch is that we should never decrease entropy but that might
be naive. At least now we'll know which direction things move in. Also
added fingerprints for syslog and splunk_hek.

Add CI to our micro-benchmark suite to make sure it doesn't accumulate
compilation errors as lading's internal API changes.

Signed-off-by: Brian L. Troutwine <brian.troutwine@datadoghq.com>
@blt blt force-pushed the fix-bench-compile branch from c6d8fa4 to 708ad35 Compare January 12, 2026 18:17
blt added 2 commits January 12, 2026 10:45
Signed-off-by: Brian L. Troutwine <brian.troutwine@datadoghq.com>
Signed-off-by: Brian L. Troutwine <brian.troutwine@datadoghq.com>
Signed-off-by: Brian L. Troutwine <brian.troutwine@datadoghq.com>
@blt blt enabled auto-merge (squash) January 12, 2026 19:28
@blt blt merged commit 9c4ce9f into main Jan 12, 2026
31 checks passed
@blt blt deleted the fix-bench-compile branch January 12, 2026 19:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants